﻿using System;
using System.Collections.Generic;
using System.Web;
using System.Web.UI;
using System.Web.UI.WebControls;

using Maticsoft.DBUtility;

public partial class UserControls_CFooterControl :  BaseUserControl
{
    // Fields
    protected string abbreviation = string.Empty;
    protected string footlogo = string.Empty;
    protected string icp = string.Empty;
    protected List<Maticsoft.Model.Friendlink> piclinks = new List<Maticsoft.Model.Friendlink>();
    protected string sitename = string.Empty;
    protected string statcode = string.Empty;
    protected List<Maticsoft.Model.Friendlink> textlinks = new List<Maticsoft.Model.Friendlink>();

    // Methods
    protected override void OnLoad(EventArgs e)
    {
        base.OnLoad(e);
        if (base.ASSystem != null)
        {
            this.abbreviation = base.ASSystem.abbreviation;
            this.footlogo = base.ASSystem.Footlogo;
            this.sitename = base.ASSystem.sitename;
            this.icp = base.ASSystem.Icp;
            this.statcode = base.ASSystem.Statcode;
        }
        Maticsoft.BLL.Friendlink friendlink = new Maticsoft.BLL.Friendlink();
        this.textlinks = friendlink.DataTableToList(DbHelperSQL.SelectByFilter("*", "(Logo is null or logo='')", "sort_order desc,id asc", "Friendlink"));
        this.piclinks = friendlink.DataTableToList(DbHelperSQL.SelectByFilter("*", "(Logo is not null and logo<>'')", "sort_order desc,id asc", "Friendlink"));
    }

}